class Class{
    static leader;
    constructor(number){
       this.number=number;
    }
    introduce(){
        return this.number;
    }
    getDisplayName(){
        return `Class ${this.number}`;
    }
    assignLeader(student){
        if(student.klass.number === this.number){
            this.leader = student;
        }
        else{
            this.leader = null;
                // console.log("It is not one of us.");
        }
    }
    //     assignLeader(student){
    //     if(student.klass.number===this.number){
    //        this.leader=student;
    //     return `My name is Tom. I am 21 years old. I am a Student. I am Leader of Class 2.`;
    // }else{
    //     return `${student.introduce()}`;
    // }
    // }
}
module.exports = Class;
